package com.zq.behavior.template_method;

public abstract class AbstractClass {
    protected abstract void connect();
    protected abstract void select();
    protected abstract void process();
    protected abstract void close();
    public void run() {
        connect();
        select();
        process();
        close();
    }
}

class ConcreteClass extends AbstractClass {

    @Override
    protected void connect() {

    }

    @Override
    protected void select() {

    }

    @Override
    protected void process() {

    }

    @Override
    protected void close() {

    }
}